home *** CD-ROM | disk | FTP | other *** search
/ Sprite 1984 - 1993 / Sprite 1984 - 1993.iso / lib / include / time.h < prev    next >
C/C++ Source or Header  |  1991-11-01  |  1KB  |  52 lines

  1. /*
  2.  * Copyright (c) 1983, 1987 Regents of the University of California.
  3.  * All rights reserved.  The Berkeley software License Agreement
  4.  * specifies the terms and conditions for redistribution.
  5.  *
  6.  *    @(#)time.h    1.2 (Berkeley) 3/4/87
  7.  */
  8.  
  9. #ifndef _TIME_H
  10. #define _TIME_H
  11.  
  12. #include <cfuncproto.h>
  13.  
  14. #ifndef _TIME_T
  15. #define _TIME_T
  16. typedef    long    time_t;
  17. #endif
  18. #ifndef _CLOCK_T
  19. #define _CLOCK_T
  20. typedef    long    clock_t;
  21. #endif
  22.  
  23. /*
  24.  * Structure returned by gmtime and localtime calls (see ctime(3)).
  25.  */
  26. struct tm {
  27.     int    tm_sec;
  28.     int    tm_min;
  29.     int    tm_hour;
  30.     int    tm_mday;
  31.     int    tm_mon;
  32.     int    tm_year;
  33.     int    tm_wday;
  34.     int    tm_yday;
  35.     int    tm_isdst;
  36.     long    tm_gmtoff;
  37.     char    *tm_zone;
  38. };
  39.  
  40. _EXTERN clock_t clock _ARGS_((void));
  41. _EXTERN time_t time _ARGS_((time_t *tp));
  42. _EXTERN time_t mktime _ARGS_((struct tm *tp));
  43. _EXTERN double difftime _ARGS_((time_t time2, time_t time1));
  44. _EXTERN struct tm *gmtime _ARGS_((_CONST time_t *tp));
  45. _EXTERN struct tm *localtime _ARGS_((_CONST time_t *tp));
  46. _EXTERN char *asctime _ARGS_((_CONST struct tm *tp));
  47. _EXTERN char *ctime _ARGS_((_CONST time_t *tp));
  48. _EXTERN int strftime _ARGS_ ((char *s, int smax, _CONST char *fmt,
  49.                              _CONST struct tm *tp));
  50.  
  51. #endif /* _TIME_H */
  52.